// 公用的
import _ from 'lodash';
//#region 高德地图
export const securityJsCode = 'aac7d76ba0a5dbde956c5694d87ee792' // 安全秘钥

export const key = 'bb28dd7fa15afc231362b033739d9420' // key
//#endregion

//#region 导出excel
export const downFiles = (blob, fileName) => {
    const url = window.URL.createObjectURL(new Blob([blob]))
    const link = document.createElement('a')
    link.href = url
    link.setAttribute('download', `${fileName}.xlsx`)
    document.body.appendChild(link)
    link.click()
    link.remove()
    window.URL.revokeObjectURL(link.href)
}
//#endregion

//#region 导出word
export const downFiles2 = (blob, fileName) => {
    const url = window.URL.createObjectURL(new Blob([blob]))
    const link = document.createElement('a')
    link.href = url
    link.setAttribute('download', `${fileName}.docx`)
    document.body.appendChild(link)
    link.click()
    link.remove()
    window.URL.revokeObjectURL(link.href)
}
//#endregion
//#region 上传图片的地址
// 测试 
export const ImageUrl_upload = 'http://120.78.240.202:8088/exSu/saveExpertSuggest'
// 线上
// export const ImageUrl_upload = 'http://120.78.240.202:8088/exSu/saveExpertSuggest'
//#endregion
// 深度拷贝对象

export const scopy = (obj) => {
    return _.cloneDeep(obj);
}
